package com.tianyang.yukuaifuzs.business.main.presenter;

import com.tianyang.yukuaifuzs.business.main.contract.MerchantDetailContract;

import rx.subscriptions.CompositeSubscription;

/**
 * Description：商户信息
 * Created by xyj on 2024/11/14
 */
public class MerchantDetailPresenter implements MerchantDetailContract.Presenter {

    private MerchantDetailContract.View mView;

    private CompositeSubscription mSubscription;

    public MerchantDetailPresenter(MerchantDetailContract.View mView) {
        this.mView = mView;
        mSubscription = new CompositeSubscription();
    }

    @Override
    public void onDestroyPresenter() {
        if (mSubscription != null && !mSubscription.isUnsubscribed()) {
            mSubscription.unsubscribe();
            mSubscription = null;
        }
        if (mView != null) {
            mView = null;
        }
    }
}
